<?php
defined('BASEPATH') OR exit('No direct script access allowed');

class Settings_mdl extends MY_Model {

    public function __construct() {
        parent::__construct();
        $this->table = 'settings';
    }

    /**
     * 获取网站设置数据
     */
    public function set_conf(){
        //判断cookie是否存在
        $this->db->where('id',1);
        $res = $this->get_one();
        $this->session->set_userdata('conf',$res);
        // if(empty(get_cookie('conf_uptime')) || get_cookie('conf_uptime') != $res['update_time']){
        //     set_cookie('conf_title', $res['title'] , 3600);
        //     set_cookie('conf_uptime',$res['update_time'],3200);
        // }

    }

}

/* End of file Settings_mdl.php */
/* Location: ./application/models/Settings_mdl.php */